package weplay.view.karaoke.lyric
{
	import flash.filters.GlowFilter;
	
	import weplay.model.ModelLocator;

	/**
	 * 解析QQ播放器 qrc歌词 
	 * 
	 */	
	public class QRCLyricParser implements LyricParser
	{
		private var qrcList:Array;
		private var qrcRunList:Array = [];
		private var _model:ModelLocator;
		
		public function QRCLyricParser()
		{
			_model = ModelLocator.getInstance();
		}
		
		public function parse(data:String):Array
		{
//			var xml:XML = new XML(data);
//			_model.view.karaokeEditor.videoPlayer.topMaskImg.filters = _model.view.karaokeEditor.videoPlayer.bottomMaskImg.filters = 
//				[new GlowFilter(16777215, 1, 4, 4, 8)];
//			qrcList = [];
//			var info:String = xml.Lyric_1.@LyricContent;
//			var line:String;
//			var listArr:Array = info.split("\n");
//			for(var i:int = 0; i < listArr.length; i++) 
//			{
//				line = listArr[i];
//				var obj:Object = {};
//				var dur:String = line.substr( line.indexOf("["), line.indexOf("]") );
//				obj.startTimer = dur.split(",")[0];  //开始时间
//				obj.endTimer = dur.split(",")[0] + dur.split(",")[1];    //
//				obj.lyric = getLineLyric(obj); // 该行歌词
//				
//				trace(listArr[i]);
//			}
//			return qrcList;
			return [];
		}
		
		
		
		
		private function getLineLyric(obj:String):String
		{
			// 匹配所有的中文、英文、字符
			return null;
		}
		
		//[2979,10225]蔡(2979,2559)健(5538,1480)雅 (7018,1158)- (8176,1460)夜(9636,1000)盲(10636,1275)症(11911,1287)
		
		public function getRunList(list:Array):Array
		{
			return null;
		}
		
		public function getTxtByPosition(p:Number):Object
		{
			return null;
		}
		
		public function getLengthByPosition(now:Number):Number
		{
			return 0;
		}
		
		public function seek(secs:Number):void
		{
		}
		
		public function topSeek(secs:Number):void
		{
		}
		
		public function bottomSeek(secs:Number):void
		{
		}
	}
}